package com.learn.support;

import org.apache.ibatis.session.SqlSession;
import org.apache.ibatis.session.SqlSessionFactory;
import org.springframework.beans.factory.FactoryBean;
import org.springframework.beans.factory.annotation.Autowired;

/**
 * Description
 * Copyright © 启明星辰 版权所有
 *
 * @author chenjiquan
 * @date 2024-08-05
 */
public class ZhouyuFactoryBean { // zhouyuFactoryBean--->UserMapper代理对象

//	private Class mapperInterface;
//
//	private SqlSession sqlSession;
//
//	public ZhouyuFactoryBean(Class mapperInterface) {
//		this.mapperInterface = mapperInterface;
//	}
//
//	@Autowired
//	public void setSqlSession(SqlSessionFactory sqlSessionFactory) {
//		sqlSessionFactory.getConfiguration().addMapper(mapperInterface);
//		this.sqlSession = sqlSessionFactory.openSession();
//	}
//
//	public Object getObject() throws Exception {
//		return sqlSession.getMapper(mapperInterface);
//	}
//
//	public Class<?> getObjectType() {
//		return mapperInterface;
//	}
}
